package org.lex.io.filesystem.tools.advcleaner;

import java.io.File;

import javax.swing.filechooser.FileNameExtensionFilter;

import org.lex.filter.Filter;


public class MyFilter implements Filter<File> {
	private FileNameExtensionFilter extNameFilter = null;

	public MyFilter(String... extensions) {
		this.extNameFilter = new FileNameExtensionFilter("Delete", extensions);
	}

	public boolean accept(File file) {
		if (null == file || true == file.isDirectory())
			return false;
		return this.extNameFilter.accept(file);
	}

}
